﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using QzEbook.BaseView;

public partial class admin_Adminstrator :Page
{
    private string type;
    protected void Page_Load(object sender, EventArgs e)
    {
        
        if(String.IsNullOrEmpty(Request["Type"]))return;
        changeType(Request["Type"]);
    }



    private void changeType(string typeString)
    {
        String path = string.Empty;
        switch (typeString)
        {
            case "user" :
                path = "UserList.ascx";
                break;
            case "pub" :
                path = "AdminBookManager.ascx";
                break;
            case "cate" :
                path = "Category.ascx";
                break;
            case "tag" :
                path = "TagList.ascx";
                break;
            default:
                path = "AdminBookManager.ascx";
                break;
        }

        Control controlDelegate=Page.LoadControl(string.Format("manager/{0}",path));
        ContentPanel.Controls.Add(controlDelegate);

    }
}
